<html>
<head>
<title>Docs For Class FileValidator</title>
<link rel="stylesheet" type="text/css" href="../../media/style.css">
</head>
<body>

<table border="0" cellspacing="0" cellpadding="0" height="48" width="100%">
  <tr>
    <td class="header_top">kassiop-system</td>
  </tr>
  <tr><td class="header_line"><img src="../../media/empty.png" width="1" height="1" border="0" alt=""  /></td></tr>
  <tr>
    <td class="header_menu">
        
                                                                                                                    
                                                                      		  [ <a href="../../classtrees_kassiop-system.html" class="menu">class tree: kassiop-system</a> ]
		  [ <a href="../../elementindex_kassiop-system.html" class="menu">index: kassiop-system</a> ]
		  	    [ <a href="../../elementindex.html" class="menu">all elements</a> ]
    </td>
  </tr>
  <tr><td class="header_line"><img src="../../media/empty.png" width="1" height="1" border="0" alt=""  /></td></tr>
</table>

<table width="100%" border="0" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="200" class="menu">
      <b>Packages:</b><br />
              <a href="../../li_kassiop.html">kassiop</a><br />
              <a href="../../li_kassiop-core.html">kassiop-core</a><br />
              <a href="../../li_kassiop-managers.html">kassiop-managers</a><br />
              <a href="../../li_kassiop-net.html">kassiop-net</a><br />
              <a href="../../li_kassiop-system.html">kassiop-system</a><br />
              <a href="../../li_kassiop-system-data.html">kassiop-system-data</a><br />
              <a href="../../li_kassiop-system-validators.html">kassiop-system-validators</a><br />
            <br /><br />
                        <b>Files:</b><br />
      	subpackage <b>data</b><br>  <div class="package">
			<a href="../../kassiop-system/data/_system---data---ValidatedFile.php.html">		ValidatedFile.php
		</a><br>
	  </div><br />
	subpackage <b>helpers</b><br>  <div class="package">
			<a href="../../kassiop-system/helpers/_system---helpers---HtmlHelper.php.html">		HtmlHelper.php
		</a><br>
			<a href="../../kassiop-system/helpers/_system---helpers---StringsHelper.php.html">		StringsHelper.php
		</a><br>
			<a href="../../kassiop-system/helpers/_system---helpers---UriHelper.php.html">		UriHelper.php
		</a><br>
	  </div><br />
	subpackage <b>utils</b><br>  <div class="package">
			<a href="../../kassiop-system/utils/_system---utils---Toolkit.php.html">		Toolkit.php
		</a><br>
	  </div><br />
	subpackage <b>validators</b><br>  <div class="package">
			<a href="../../kassiop-system/validators/_system---validators---BooleanValidator.php.html">		BooleanValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---ChoiceDatabaseValidator.php.html">		ChoiceDatabaseValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---ChoiceValidator.php.html">		ChoiceValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---DateTimeValidator.php.html">		DateTimeValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---DateValidator.php.html">		DateValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---EmailValidator.php.html">		EmailValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---FieldsCompareValidator.php.html">		FieldsCompareValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---FileValidator.php.html">		FileValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---FloatValidator.php.html">		FloatValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---IntegerValidator.php.html">		IntegerValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---RegexValidator.php.html">		RegexValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---SlugValidator.php.html">		SlugValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---StringValidator.php.html">		StringValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---UniqueValidator.php.html">		UniqueValidator.php
		</a><br>
			<a href="../../kassiop-system/validators/_system---validators---UriValidator.php.html">		UriValidator.php
		</a><br>
	  </div><br />
      
      
            <b>Classes:</b><br />
        <div class="package">
	validators<br />	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/BooleanValidator.html">BooleanValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/ChoiceDatabaseValidator.html">ChoiceDatabaseValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/ChoiceValidator.html">ChoiceValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/DateTimeValidator.html">DateTimeValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/DateValidator.html">DateValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/EmailValidator.html">EmailValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/FieldsCompareValidator.html">FieldsCompareValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/FileValidator.html">FileValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/FloatValidator.html">FloatValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/IntegerValidator.html">IntegerValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/RegexValidator.html">RegexValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/SlugValidator.html">SlugValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/StringValidator.html">StringValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/UniqueValidator.html">UniqueValidator</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/validators/UriValidator.html">UriValidator</a><br />
	  </div>
  <div class="package">
	helpers<br />	    &nbsp;&nbsp;		<a href="../../kassiop-system/helpers/HtmlHelper.html">HtmlHelper</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/helpers/StringsHelper.html">StringsHelper</a><br />
	    &nbsp;&nbsp;		<a href="../../kassiop-system/helpers/UriHelper.html">UriHelper</a><br />
	  </div>
  <div class="package">
	utils<br />	    &nbsp;&nbsp;		<a href="../../kassiop-system/utils/Toolkit.html">Toolkit</a><br />
	  </div>
  <div class="package">
	data<br />	    &nbsp;&nbsp;		<a href="../../kassiop-system/data/ValidatedFile.html">ValidatedFile</a><br />
	  </div>
                </td>
    <td>
      <table cellpadding="10" cellspacing="0" width="100%" border="0"><tr><td valign="top">

<h1>Class: FileValidator</h1>
Source Location: /system/validators/FileValidator.php<br /><br />


<table width="100%" border="0">
<tr><td valign="top">

<h3><a href="#class_details">Class Overview</a></h3>
<pre><a href="../../kassiop-system-validators/base/BaseValidator.html">BaseValidator</a>
   |
   --FileValidator</pre><br />
<div class="description">FileValidator validates an uploaded file.</div><br /><br />
<h4>Author(s):</h4>
<ul>
          <li>NairuS</li>
            </ul>




        
    
<h4>Version:</h4>
<ul>
  <li>1.2 $Rev: 90 $ $Date: 2011-01-16 10:23:26 +0100 (Dim, 16 jan 2011) $ $Author: nicolas.surian $</li>
</ul>

        
</td>

<td valign="top">
<h3><a href="#class_vars">Variables</a></h3>
<ul>
    <li><a href="../../kassiop-system/validators/FileValidator.html#var$cantWriteKey">$cantWriteKey</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#var$extensionKey">$extensionKey</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#var$maxSizeKey">$maxSizeKey</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#var$mimeCategoriesKey">$mimeCategoriesKey</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#var$mimeTypeGuessersKey">$mimeTypeGuessersKey</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#var$mimeTypeKey">$mimeTypeKey</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#var$noTmpDirKey">$noTmpDirKey</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#var$partialKey">$partialKey</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#var$pathKey">$pathKey</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#var$validatedFileClassKey">$validatedFileClassKey</a></li>
  </ul>
</td>


<td valign="top">
<h3><a href="#class_methods">Methods</a></h3>
<ul>
    <li><a href="../../kassiop-system/validators/FileValidator.html#methodconfigure">configure</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#methoddoClean">doClean</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#methodgetMimeType">getMimeType</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#methodgetMimeTypesFromCategory">getMimeTypesFromCategory</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#methodguessFromFileBinary">guessFromFileBinary</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#methodguessFromFileinfo">guessFromFileinfo</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#methodguessFromMimeContentType">guessFromMimeContentType</a></li>
    <li><a href="../../kassiop-system/validators/FileValidator.html#methodisEmpty">isEmpty</a></li>
  </ul>
</td>

</tr></table>
<hr />

<table width="100%" border="0"><tr>




<td valign="top">
<h3>Inherited Variables</h3>
<div class="tags">
<h4>Class: <a href="../../kassiop-system-validators/base/BaseValidator.html">BaseValidator</a></h4>
<dl>
<dt>
  <a href="../../kassiop-system-validators/base/BaseValidator.html#var$charset">BaseValidator::$charset</a>
  </dt>
<dd>
   
</dd>
<dt>
  <a href="../../kassiop-system-validators/base/BaseValidator.html#var$emptyValueKey">BaseValidator::$emptyValueKey</a>
  </dt>
<dd>
   
</dd>
<dt>
  <a href="../../kassiop-system-validators/base/BaseValidator.html#var$invalidKey">BaseValidator::$invalidKey</a>
  </dt>
<dd>
   
</dd>
<dt>
  <a href="../../kassiop-system-validators/base/BaseValidator.html#var$invalidMessage">BaseValidator::$invalidMessage</a>
  </dt>
<dd>
   
</dd>
<dt>
  <a href="../../kassiop-system-validators/base/BaseValidator.html#var$messages">BaseValidator::$messages</a>
  </dt>
<dd>
   
</dd>
<dt>
  <a href="../../kassiop-system-validators/base/BaseValidator.html#var$options">BaseValidator::$options</a>
  </dt>
<dd>
   
</dd>
<dt>
  <a href="../../kassiop-system-validators/base/BaseValidator.html#var$requiredKey">BaseValidator::$requiredKey</a>
  </dt>
<dd>
   
</dd>
<dt>
  <a href="../../kassiop-system-validators/base/BaseValidator.html#var$requiredMessage">BaseValidator::$requiredMessage</a>
  </dt>
<dd>
   
</dd>
<dt>
  <a href="../../kassiop-system-validators/base/BaseValidator.html#var$trimKey">BaseValidator::$trimKey</a>
  </dt>
<dd>
   
</dd>
</dl>
</div>
</td>

<td valign="top">
<h3>Inherited Methods</h3>
<div class="tags">
<h4>Class: <a href="../../kassiop-system-validators/base/BaseValidator.html">BaseValidator</a></h4>
<dl>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#method__construct">BaseValidator::__construct()</a>
  </dt>
  <dd>
    Create an instance of BaseValidator
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodaddMessage">BaseValidator::addMessage()</a>
  </dt>
  <dd>
    Adds an message.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodaddOption">BaseValidator::addOption()</a>
  </dt>
  <dd>
    Adds an option.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodclean">BaseValidator::clean()</a>
  </dt>
  <dd>
    Cleans the input value.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodconfigure">BaseValidator::configure()</a>
  </dt>
  <dd>
    Configures the current validator.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methoddoClean">BaseValidator::doClean()</a>
  </dt>
  <dd>
    Cleans the input value.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodgetCharset">BaseValidator::getCharset()</a>
  </dt>
  <dd>
    Returns the charset to use when validating strings.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodgetEmptyValue">BaseValidator::getEmptyValue()</a>
  </dt>
  <dd>
    Returns an empty value for this validator.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodgetMessage">BaseValidator::getMessage()</a>
  </dt>
  <dd>
    Returns the value of the message name passed-in or null if not exists.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodgetMessages">BaseValidator::getMessages()</a>
  </dt>
  <dd>
    Return all the messages configured.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodgetOption">BaseValidator::getOption()</a>
  </dt>
  <dd>
    Returns the value of the option name passed-in or null if not exists.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodgetOptions">BaseValidator::getOptions()</a>
  </dt>
  <dd>
    Return all the options configured.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodhasMessage">BaseValidator::hasMessage()</a>
  </dt>
  <dd>
    Returns true if the message name exists.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodhasOption">BaseValidator::hasOption()</a>
  </dt>
  <dd>
    Returns true if the option name exists.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodisEmpty">BaseValidator::isEmpty()</a>
  </dt>
  <dd>
    Returns true if the value is empty.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodsetCharset">BaseValidator::setCharset()</a>
  </dt>
  <dd>
    Sets the charset to use when validating strings.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodsetMessage">BaseValidator::setMessage()</a>
  </dt>
  <dd>
    Tries to set an existant message.
  </dd>
    <dt>
    <a href="../../kassiop-system-validators/base/BaseValidator.html#methodsetOption">BaseValidator::setOption()</a>
  </dt>
  <dd>
    Tries to set an existant option.
  </dd>
  </dl>
</div>
</td>

</tr></table>
<hr />

<a name="class_details"></a>
<h3>Class Details</h3>
<div class="tags">
[line 46]<br />
FileValidator validates an uploaded file.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>author:</b>&nbsp;&nbsp;</td><td>NairuS</td>
  </tr>
  <tr>
    <td><b>version:</b>&nbsp;&nbsp;</td><td>1.2 $Rev: 90 $ $Date: 2011-01-16 10:23:26 +0100 (Dim, 16 jan 2011) $ $Author: nicolas.surian $</td>
  </tr>
</table>
</div>
</div><br /><br />
<div class="top">[ <a href="#top">Top</a> ]</div><br />

<hr />
<a name="class_vars"></a>
<h3>Class Variables</h3>
<div class="tags">
	<a name="var$cantWriteKey"></a>
	<p></p>
	<h4>static $cantWriteKey = <span class="value">&nbsp;'cant_write'</span></h4>
	<p>[line 53]</p>
  Defines the cant_write option key.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
  </tr>
</table>
</div>

  <br />
	<div class="tags">
  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td><b>Type:</b>&nbsp;&nbsp;</td>
      <td>string</td>
    </tr>
      </table>
	</div><br /><br />
	<div class="top">[ <a href="#top">Top</a> ]</div><br />
	<a name="var$extensionKey"></a>
	<p></p>
	<h4>static $extensionKey = <span class="value">&nbsp;'extension'</span></h4>
	<p>[line 60]</p>
  Defines the extension option key.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
  </tr>
</table>
</div>

  <br />
	<div class="tags">
  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td><b>Type:</b>&nbsp;&nbsp;</td>
      <td>string</td>
    </tr>
      </table>
	</div><br /><br />
	<div class="top">[ <a href="#top">Top</a> ]</div><br />
	<a name="var$maxSizeKey"></a>
	<p></p>
	<h4>static $maxSizeKey = <span class="value">&nbsp;'max_size'</span></h4>
	<p>[line 67]</p>
  Defines the max_size option key.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
  </tr>
</table>
</div>

  <br />
	<div class="tags">
  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td><b>Type:</b>&nbsp;&nbsp;</td>
      <td>string</td>
    </tr>
      </table>
	</div><br /><br />
	<div class="top">[ <a href="#top">Top</a> ]</div><br />
	<a name="var$mimeCategoriesKey"></a>
	<p></p>
	<h4>static $mimeCategoriesKey = <span class="value">&nbsp;'mime_categories'</span></h4>
	<p>[line 75]</p>
  Defines the mime_categories option key.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
  </tr>
</table>
</div>

  <br />
	<div class="tags">
  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td><b>Type:</b>&nbsp;&nbsp;</td>
      <td>string</td>
    </tr>
      </table>
	</div><br /><br />
	<div class="top">[ <a href="#top">Top</a> ]</div><br />
	<a name="var$mimeTypeGuessersKey"></a>
	<p></p>
	<h4>static $mimeTypeGuessersKey = <span class="value">&nbsp;'mime_type_guessers'</span></h4>
	<p>[line 82]</p>
  Defines the mime_type_guessers option key.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
  </tr>
</table>
</div>

  <br />
	<div class="tags">
  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td><b>Type:</b>&nbsp;&nbsp;</td>
      <td>string</td>
    </tr>
      </table>
	</div><br /><br />
	<div class="top">[ <a href="#top">Top</a> ]</div><br />
	<a name="var$mimeTypeKey"></a>
	<p></p>
	<h4>static $mimeTypeKey = <span class="value">&nbsp;'mime_types'</span></h4>
	<p>[line 89]</p>
  Defines the mime_types option key.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
  </tr>
</table>
</div>

  <br />
	<div class="tags">
  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td><b>Type:</b>&nbsp;&nbsp;</td>
      <td>string</td>
    </tr>
      </table>
	</div><br /><br />
	<div class="top">[ <a href="#top">Top</a> ]</div><br />
	<a name="var$noTmpDirKey"></a>
	<p></p>
	<h4>static $noTmpDirKey = <span class="value">&nbsp;'no_tmp_dir'</span></h4>
	<p>[line 95]</p>
  Defines the no_tmp_dir option key.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
  </tr>
</table>
</div>

  <br />
	<div class="tags">
  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td><b>Type:</b>&nbsp;&nbsp;</td>
      <td>string</td>
    </tr>
      </table>
	</div><br /><br />
	<div class="top">[ <a href="#top">Top</a> ]</div><br />
	<a name="var$partialKey"></a>
	<p></p>
	<h4>static $partialKey = <span class="value">&nbsp;'partial'</span></h4>
	<p>[line 102]</p>
  Defines the partial option key.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
  </tr>
</table>
</div>

  <br />
	<div class="tags">
  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td><b>Type:</b>&nbsp;&nbsp;</td>
      <td>string</td>
    </tr>
      </table>
	</div><br /><br />
	<div class="top">[ <a href="#top">Top</a> ]</div><br />
	<a name="var$pathKey"></a>
	<p></p>
	<h4>static $pathKey = <span class="value">&nbsp;'path'</span></h4>
	<p>[line 109]</p>
  Defines the path option key.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
  </tr>
</table>
</div>

  <br />
	<div class="tags">
  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td><b>Type:</b>&nbsp;&nbsp;</td>
      <td>string</td>
    </tr>
      </table>
	</div><br /><br />
	<div class="top">[ <a href="#top">Top</a> ]</div><br />
	<a name="var$validatedFileClassKey"></a>
	<p></p>
	<h4>static $validatedFileClassKey = <span class="value">&nbsp;'validated_file_class'</span></h4>
	<p>[line 116]</p>
  Defines the validated_file_class option key.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>public</td>
  </tr>
</table>
</div>

  <br />
	<div class="tags">
  <table border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td><b>Type:</b>&nbsp;&nbsp;</td>
      <td>string</td>
    </tr>
      </table>
	</div><br /><br />
	<div class="top">[ <a href="#top">Top</a> ]</div><br />
</div><br />

<hr />
<a name="class_methods"></a>
<h3>Class Methods</h3>
<div class="tags">

  <hr />
	<a name="methodconfigure"></a>
	<h3>method configure <span class="smalllinenumber">[line 147]</span></h3>
	<div class="function">
    <table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
    <table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
		<code>void configure(
)</code>
    </td></tr></table>
    </td></tr></table><br />
	
		Configures the current validator.<br /><br /><p>Available options:</p><p>* max_size:             The maximum file size in bytes (cannot exceed upload_max_filesize in php.ini)   * mime_types:           Allowed mime types array or category (available categories: web_images)   * mime_type_guessers:   An array of mime type guesser PHP callables (must return the mime type or null)   * mime_categories:      An array of mime type categories (web_images is defined by default)   * path:                 The path where to save the file - as used by the ValidatedFile class (optional)   * validated_file_class: Name of the class that manages the cleaned uploaded file (optional)</p><p>There are 3 built-in mime type guessers:</p><p>* guessFromFileinfo:        Uses the finfo_open() function (from the Fileinfo PECL extension)   * guessFromMimeContentType: Uses the mime_content_type() function (deprecated)   * guessFromFileBinary:      Uses the file binary (only works on *nix system)</p><p>Available error codes:</p><p>* max_size   * mime_types   * partial   * no_tmp_dir   * cant_write   * extension</p><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>see:</b>&nbsp;&nbsp;</td><td><a href="../../kassiop-system-validators/base/BaseValidator.html">BaseValidator</a></td>
  </tr>
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>protected</td>
  </tr>
</table>
</div>
<br /><br />

	Overrides <a href="../../kassiop-system-validators/base/BaseValidator.html#methodconfigure">BaseValidator::configure()</a> (Configures the current validator.)<br /><br />
        <div class="top">[ <a href="#top">Top</a> ]</div>
  </div>
  <hr />
	<a name="methoddoClean"></a>
	<h3>method doClean <span class="smalllinenumber">[line 198]</span></h3>
	<div class="function">
    <table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
    <table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
		<code>void doClean(

$value)</code>
    </td></tr></table>
    </td></tr></table><br />
	
		This validator always returns a ValidatedFile object.<br /><br /><p>The input value must be an array with the following keys:</p><p>* tmp_name: The absolute temporary path to the file   * name:     The original file name (optional)   * type:     The file content type (optional)   * error:    The error code (optional)   * size:     The file size in bytes (optional)</p><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>see:</b>&nbsp;&nbsp;</td><td><a href="../../kassiop-system-validators/base/BaseValidator.html">BaseValidator</a></td>
  </tr>
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>protected</td>
  </tr>
</table>
</div>
<br /><br />

	Overrides <a href="../../kassiop-system-validators/base/BaseValidator.html#methoddoClean">BaseValidator::doClean()</a> (Cleans the input value.)<br /><br />
        <h4>Parameters:</h4>
    <div class="tags">
    <table border="0" cellspacing="0" cellpadding="0">
          <tr>
        <td class="type">&nbsp;&nbsp;</td>
        <td><b>$value</b>&nbsp;&nbsp;</td>
        <td></td>
      </tr>
        </table>
    </div><br />
        <div class="top">[ <a href="#top">Top</a> ]</div>
  </div>
  <hr />
	<a name="methodgetMimeType"></a>
	<h3>method getMimeType <span class="smalllinenumber">[line 296]</span></h3>
	<div class="function">
    <table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
    <table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
		<code>string getMimeType(
string
$file, string
$fallback)</code>
    </td></tr></table>
    </td></tr></table><br />
	
		Returns the mime type of a file.<br /><br /><p>This methods call each mime_type_guessers option callables to  guess the mime type.</p><p>This method always returns a lower-cased string as mime types are case-insensitive  as per the RFC 2616 (http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.7).</p><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>return:</b>&nbsp;&nbsp;</td><td>The mime type of the file (fallback is returned if not guessable)</td>
  </tr>
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>protected</td>
  </tr>
</table>
</div>
<br /><br />

	
        <h4>Parameters:</h4>
    <div class="tags">
    <table border="0" cellspacing="0" cellpadding="0">
          <tr>
        <td class="type">string&nbsp;&nbsp;</td>
        <td><b>$file</b>&nbsp;&nbsp;</td>
        <td>The absolute path of a file</td>
      </tr>
          <tr>
        <td class="type">string&nbsp;&nbsp;</td>
        <td><b>$fallback</b>&nbsp;&nbsp;</td>
        <td>The default mime type to return if not guessable</td>
      </tr>
        </table>
    </div><br />
        <div class="top">[ <a href="#top">Top</a> ]</div>
  </div>
  <hr />
	<a name="methodgetMimeTypesFromCategory"></a>
	<h3>method getMimeTypesFromCategory <span class="smalllinenumber">[line 396]</span></h3>
	<div class="function">
    <table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
    <table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
		<code>string getMimeTypesFromCategory(
string
$category)</code>
    </td></tr></table>
    </td></tr></table><br />
	
		Guess the file mime with tha Category array.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>return:</b>&nbsp;&nbsp;</td><td>The mime type</td>
  </tr>
  <tr>
    <td><b>throws:</b>&nbsp;&nbsp;</td><td>InvalidArgumentException</td>
  </tr>
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>protected</td>
  </tr>
</table>
</div>
<br /><br />

	
        <h4>Parameters:</h4>
    <div class="tags">
    <table border="0" cellspacing="0" cellpadding="0">
          <tr>
        <td class="type">string&nbsp;&nbsp;</td>
        <td><b>$category</b>&nbsp;&nbsp;</td>
        <td></td>
      </tr>
        </table>
    </div><br />
        <div class="top">[ <a href="#top">Top</a> ]</div>
  </div>
  <hr />
	<a name="methodguessFromFileBinary"></a>
	<h3>method guessFromFileBinary <span class="smalllinenumber">[line 365]</span></h3>
	<div class="function">
    <table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
    <table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
		<code>string guessFromFileBinary(
string
$file)</code>
    </td></tr></table>
    </td></tr></table><br />
	
		Guess the file mime type with the file binary (only available on *nix)<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>return:</b>&nbsp;&nbsp;</td><td>The mime type of the file (null if not guessable)</td>
  </tr>
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>protected</td>
  </tr>
</table>
</div>
<br /><br />

	
        <h4>Parameters:</h4>
    <div class="tags">
    <table border="0" cellspacing="0" cellpadding="0">
          <tr>
        <td class="type">string&nbsp;&nbsp;</td>
        <td><b>$file</b>&nbsp;&nbsp;</td>
        <td>The absolute path of a file</td>
      </tr>
        </table>
    </div><br />
        <div class="top">[ <a href="#top">Top</a> ]</div>
  </div>
  <hr />
	<a name="methodguessFromFileinfo"></a>
	<h3>method guessFromFileinfo <span class="smalllinenumber">[line 318]</span></h3>
	<div class="function">
    <table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
    <table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
		<code>string guessFromFileinfo(
string
$file)</code>
    </td></tr></table>
    </td></tr></table><br />
	
		Guess the file mime type with PECL Fileinfo extension<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>return:</b>&nbsp;&nbsp;</td><td>The mime type of the file (null if not guessable)</td>
  </tr>
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>protected</td>
  </tr>
</table>
</div>
<br /><br />

	
        <h4>Parameters:</h4>
    <div class="tags">
    <table border="0" cellspacing="0" cellpadding="0">
          <tr>
        <td class="type">string&nbsp;&nbsp;</td>
        <td><b>$file</b>&nbsp;&nbsp;</td>
        <td>The absolute path of a file</td>
      </tr>
        </table>
    </div><br />
        <div class="top">[ <a href="#top">Top</a> ]</div>
  </div>
  <hr />
	<a name="methodguessFromMimeContentType"></a>
	<h3>method guessFromMimeContentType <span class="smalllinenumber">[line 348]</span></h3>
	<div class="function">
    <table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
    <table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
		<code>string guessFromMimeContentType(
string
$file)</code>
    </td></tr></table>
    </td></tr></table><br />
	
		Guess the file mime type with mime_content_type function (deprecated)<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>return:</b>&nbsp;&nbsp;</td><td>The mime type of the file (null if not guessable)</td>
  </tr>
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>protected</td>
  </tr>
</table>
</div>
<br /><br />

	
        <h4>Parameters:</h4>
    <div class="tags">
    <table border="0" cellspacing="0" cellpadding="0">
          <tr>
        <td class="type">string&nbsp;&nbsp;</td>
        <td><b>$file</b>&nbsp;&nbsp;</td>
        <td>The absolute path of a file</td>
      </tr>
        </table>
    </div><br />
        <div class="top">[ <a href="#top">Top</a> ]</div>
  </div>
  <hr />
	<a name="methodisEmpty"></a>
	<h3>method isEmpty <span class="smalllinenumber">[line 413]</span></h3>
	<div class="function">
    <table width="90%" border="0" cellspacing="0" cellpadding="1"><tr><td class="code_border">
    <table width="100%" border="0" cellspacing="0" cellpadding="2"><tr><td class="code">
		<code>bool isEmpty(
mixed
$value)</code>
    </td></tr></table>
    </td></tr></table><br />
	
		Returns true if the value is empty.<br /><br /><br /><br />
<h4>Tags:</h4>
<div class="tags">
<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><b>return:</b>&nbsp;&nbsp;</td><td>true if the value is empty, false otherwise</td>
  </tr>
  <tr>
    <td><b>see:</b>&nbsp;&nbsp;</td><td><a href="../../kassiop-system-validators/base/BaseValidator.html">BaseValidator</a></td>
  </tr>
  <tr>
    <td><b>access:</b>&nbsp;&nbsp;</td><td>protected</td>
  </tr>
</table>
</div>
<br /><br />

	Overrides <a href="../../kassiop-system-validators/base/BaseValidator.html#methodisEmpty">BaseValidator::isEmpty()</a> (Returns true if the value is empty.)<br /><br />
        <h4>Parameters:</h4>
    <div class="tags">
    <table border="0" cellspacing="0" cellpadding="0">
          <tr>
        <td class="type">mixed&nbsp;&nbsp;</td>
        <td><b>$value</b>&nbsp;&nbsp;</td>
        <td>The input value</td>
      </tr>
        </table>
    </div><br />
        <div class="top">[ <a href="#top">Top</a> ]</div>
  </div>
</div><br />


        <div class="credit">
		    <hr />
		    Documentation generated on Thu, 20 Jan 2011 14:38:58 +0100 by <a href="http://www.phpdoc.org">phpDocumentor 1.4.3</a>
	      </div>
      </td></tr></table>
    </td>
  </tr>
</table>

</body>
</html>